UAT Test Plan — Service Order Lockout
| Field | Value |
|---|
| Version | 2.0 |
| Date | February 27, 2026 |
| Project | Bestway BC Development |
| Environment | Business Central Sandbox |
This test plan covers the v1.1.0.0 release, which includes all defect fixes from the pre-UAT code review plus new features (stale lock auto-release, Release Lock action, configuration page). The BW-CS-SERVICE permission set must be assigned to all CS test users before testing begins. SUPER test users do NOT need BW-CS-SERVICE — they are permitted through the access check automatically.
Overview
This test plan validates the Service Order Lockout extension (v1.1.0.0) for Microsoft Dynamics 365 Business Central. The extension prevents two customer service representatives from simultaneously editing the same service order by detecting concurrent access, displaying a notification to the second user, and switching that user to read-only mode. A Live Status column on the Service Orders list allows agents to identify at a glance which orders are currently being worked on.\n\nv1.1.0.0 adds stale lock auto-release (configurable timeout), a Release Lock action for SUPER users, a configuration page with an enable/disable toggle, proper record navigation lock handling, and the BW-CS-SERVICE permission set for role-based access control.
Extension Object Summary
| Object | ID | Extends | Purpose |
|---|
| Table Extension | 52400 | Service Header | Adds Check Status (Boolean), Live Status (Option), Open By User ID (Text[50]), and Locked At (DateTime) fields. |
| Table | 52401 | N/A | Service Order Lockout Setup — singleton configuration table (lockout toggle, stale lock timeout). |
| Page Extension | 52400 | Service Orders (list) | Adds Live Status column (computed from page variable) before the standard Status column. |
| Page Extension | 52401 | Service Order (card) | Lock-on-open, unlock-on-close, record navigation handling, Release Lock action, BW-CS-SERVICE permission check. |
| Page | 52402 | N/A | Service Order Lockout Setup — configuration card page (Lockout Enabled toggle, Stale Lock Timeout). |
| Permission Set | 52401 | N/A | BW-CS-SERVICE — grants Read/Modify on Service Header and Read on Lockout Setup. |
| Codeunit | 52402 | N/A | Upgrade codeunit — clears stale locks during v1.0 → v1.1 migration only. |
Prerequisites
Test Area 1: Service Orders List — Live Status Column
Requirement: A 'Live Status' column showing 'Open' or 'In Progress' must appear on the Service Orders list view.
Verify that the Live Status column is present, correctly positioned, non-editable, and accurately reflects the lock state of each order. The column is computed from a page variable (not a persisted field) and is hidden when lockout is disabled.
TC-1.1: Live Status Column Is Present and Correctly Positioned
| Step | Action | Expected Result |
|---|
| 1 | Log in as User A (BW-CS-SERVICE role). Navigate to Service Orders and open the list. | The Service Orders list opens showing orders. |
| 2 | Inspect the column headers in the list. | A 'Live Status' column is visible and is positioned immediately before the standard 'Status' column. |
| 3 | Attempt to click into or edit the Live Status column for any row. | The column is non-editable — no cursor appears and no value can be entered. |
TC-1.2: Live Status Shows 'Open' for Orders Not Currently Being Worked
| Step | Action | Expected Result |
|---|
| 1 | Confirm that no test service orders are currently open in any active session. | No user has any test orders open. |
| 2 | In User A's session, view the Service Orders list. | The list is visible with multiple service orders. |
| 3 | Locate at least 3 service orders and observe the Live Status column for each. | Each order displays 'Open' in the Live Status column. |
TC-1.3: Live Status Shows 'In Progress' While an Order Is Open
| Step | Action | Expected Result |
|---|
| 1 | User A opens a service order (e.g., the first one in the list). Leave it open. | The service order card is open in User A's session. |
| 2 | In a separate session, User B navigates to the Service Orders list. | User B can see the list. |
| 3 | User B locates the same service order in the list and observes the Live Status column. | The order shows 'In Progress' in the Live Status column. |
| 4 | User B observes the Live Status for other orders not currently open. | All other orders still show 'Open'. |
Test Area 2: Concurrent Access — Record Locking
Requirement: When a second user opens an order already open by another user, they must see a message identifying the first user and be placed in read-only mode.
Verify the lockout message, read-only enforcement, and that the first user retains full edit access.
If you have access to inspect table data, confirm after step 1 that Check Status = true, Open By User ID = User A's BC User Name, and Locked At is populated with a recent timestamp on the service order record.
TC-2.1: First Opener Acquires the Lock
| Step | Action | Expected Result |
|---|
| 1 | User A opens a service order card. | The service order card opens and is fully editable for User A. No message is shown. |
| 2 | (Optional) Inspect the Service Header record in Developer Tools or an admin page. | Check Status = true. Open By User ID = User A's BC User Name. Locked At = current timestamp. |
| 3 | User A edits a field (e.g., updates the Description) and saves. | The change saves successfully. No error or restriction is encountered. |
TC-2.2: Second User Receives the Lockout Message
| Step | Action | Expected Result |
|---|
| 1 | User A has the order open from TC-2.1. In a separate session, User B navigates to and opens the same order. | A message dialog is displayed to User B. |
| 2 | Read the message text. | The message reads: '[User A's User Name] is currently working on this Service Order. Click OK to switch to View Only Mode.' The user name shown must match User A's actual BC User Name. |
| 3 | User B clicks OK. | The dialog closes and the service order card is displayed to User B. |
TC-2.3: Second User's View Is Read-Only After Lockout
| Step | Action | Expected Result |
|---|
| 1 | After clicking OK (TC-2.2), User B attempts to click into and edit any field on the order. | No fields are editable. The page is in read-only/view mode. |
| 2 | User B attempts to use any action that modifies data (e.g., Add Line, Post). | Data-modifying actions are hidden or disabled. User B cannot make changes. |
| 3 | User B can still scroll through and read all information on the order. | All data is visible and readable. Only editing is restricted. |
TC-2.4: First User Retains Full Edit Access While Lock Is Active
| Step | Action | Expected Result |
|---|
| 1 | While User B views the order in read-only mode, return to User A's session. | User A's view of the service order is unchanged. |
| 2 | User A edits multiple fields and saves. | All fields are editable. User A can make and save changes without restriction or error. |
Test Area 3: Lock Release on Close
Requirement: When the locking user closes the order, the lock must be released so the next opener gets full edit access.
Verify the lock releases correctly on close and that a read-only viewer closing the order does not prematurely release the lock.
TC-3.1: Lock Releases When the Locking User Closes the Order
| Step | Action | Expected Result |
|---|
| 1 | User A closes the service order card (navigates away or closes the tab). | The card closes normally with no errors. |
| 2 | (Optional) Inspect the Service Header record. | Check Status = false. Open By User ID is blank. Locked At is cleared. |
| 3 | Observe the Live Status column in the list for the order User A just closed. | The order now shows 'Open' in the Live Status column. |
TC-3.2: Next User Can Edit After Lock Is Released
| Step | Action | Expected Result |
|---|
| 1 | After User A closes the order (TC-3.1), User B closes their read-only view and then reopens the same order. | No lockout message is shown to User B. |
| 2 | User B attempts to edit a field on the order. | The page is fully editable. User B can make and save changes without restriction. |
| 3 | (Optional) Inspect the Service Header record. | Check Status = true. Open By User ID = User B's BC User Name. |
TC-3.3: Closing a Read-Only View Does Not Release the Lock
| Step | Action | Expected Result |
|---|
| 1 | User A opens a second service order and holds it open. | User A holds the lock. |
| 2 | User B opens the same order, receives the lockout message, clicks OK, and is in read-only mode. | User B is viewing the order in read-only mode. |
| 3 | User B closes their read-only view. | The card closes normally for User B. No error occurs. |
| 4 | Confirm User A's session still has the order open and editable. | User A's card is still open and editable. The lock has NOT been released by User B closing. |
Test Area 4: Edge Cases
TC-4.1: Same User Opens the Same Order in a Second Session
| Step | Action | Expected Result |
|---|
| 1 | User A opens a service order in one browser window. User A then opens a second browser window and opens the same order. | Observe and document what happens. |
| 2 | Note whether a lockout message appears in the second window. | Expected: No lockout message — Open By User ID matches the current user. The order is editable in both windows. Document the actual result. |
| 3 | User A closes one of the two windows. | Document whether the lock is released when one session closes while the other remains open. Confirm whether this is acceptable behavior. |
TC-4.2: Posting a Service Order Clears the Lock
| Step | Action | Expected Result |
|---|
| 1 | User A opens a service order that is in a postable state and posts it. | The order is posted successfully. |
| 2 | (Optional) Inspect the posted Service Header record. | Check Status = false. Open By User ID is empty. |
| 3 | Verify the posted order no longer appears in the open Service Orders list. | The posted order is absent from the open orders list. |
Test Area 5: Role Scoping — BW-CS-SERVICE Permission Set
Requirement: Only users with the BW-CS-SERVICE permission set (or SUPER role) can access Service Orders when lockout is enabled.
Verify that the permission check correctly gates access based on the BW-CS-SERVICE permission set and that SUPER users are permitted through without it.
TC-5.1: CS Users with BW-CS-SERVICE Experience Lockout Behavior Normally
| Step | Action | Expected Result |
|---|
| 1 | User A (BW-CS-SERVICE role) opens a service order. | The card opens normally with no error or unexpected dialog. User A has full edit access. |
| 2 | User B (BW-CS-SERVICE role) opens the same order. | User B receives the lockout message identifying User A by name and is placed in read-only mode. |
| 3 | User A closes the order. User B reopens it. | User B can now open and edit the order normally. No lockout message appears. |
TC-5.2: User Without BW-CS-SERVICE or SUPER Is Blocked
| Step | Action | Expected Result |
|---|
| 1 | User D (no BW-CS-SERVICE, no SUPER) attempts to open a service order card. | An error message is displayed. |
| 2 | Read the error message text. | The message reads: 'You need the BW-CS-SERVICE permission set to access Service Orders. Contact your system administrator to request access.' |
| 3 | Confirm User D cannot proceed past the error. | The Service Order card does not open. User D is blocked. |
TC-5.3: SUPER User Without BW-CS-SERVICE Can Access Service Orders
| Step | Action | Expected Result |
|---|
| 1 | User C (SUPER role, no BW-CS-SERVICE) opens a service order card. | The card opens normally. No permission error is shown. |
| 2 | User C edits a field and saves. | The change saves successfully. SUPER users have full access. |
Test Area 6: User Interface Quality
TC-6.1: Internal Fields Are Not Visible on the Service Order Card
| Step | Action | Expected Result |
|---|
| 1 | User A opens any service order card. | The service order card opens normally. |
| 2 | Inspect all visible fields in the card header and all FastTabs. | The field 'Check Status' (Boolean) is NOT visible anywhere on the card. |
| 3 | Continue inspecting all tabs and sections. | The field 'Open By User ID' (text) is NOT visible anywhere on the card. |
TC-6.2: Live Status Column Shows Clean Values
| Step | Action | Expected Result |
|---|
| 1 | View the Service Orders list with a mix of locked and unlocked orders. | The Live Status column shows only 'Open' or 'In Progress'. No blank values, no numeric option indexes (0, 1, 2), and no raw field names appear. |
| 2 | Confirm the column header reads 'Live Status'. | Column header is correctly labeled 'Live Status' (not 'LiveStatus' or 'Check Status'). |
Test Area 7: Regression — Existing Service Order Functionality
TC-7.1: Standard Service Order Operations Are Unaffected
| Step | Action | Expected Result |
|---|
| 1 | User A opens a service order not currently locked by anyone. | The order opens normally. No error messages or unexpected dialogs appear. |
| 2 | User A adds a service line, updates the description, and changes the responsible technician. | All standard operations complete without error. |
| 3 | User A saves and closes the order. | The order saves correctly and the lock is released (Check Status = false). |
TC-7.2: Existing Service Orders List Filters and Views Still Work
| Step | Action | Expected Result |
|---|
| 1 | Open the Service Orders list and apply a filter (e.g., by Release Status = Open). | The filtered view loads correctly and shows only matching orders. |
| 2 | Apply additional filters (by Customer No., Responsible, or date range). | Additional filters work correctly and do not interact with the Live Status column. |
| 3 | Remove all filters and confirm the Live Status column is still present. | The Live Status column persists across filter changes. |
This test validates that the CurrPage.Update() render-loop fix has been applied. In the original v1.0 code, calling CurrPage.Update() from OnAfterGetRecord caused the list to reload continuously, producing severe performance degradation on any list with real data.
| Step | Action | Expected Result |
|---|
| 1 | Open the Service Orders list with 30 or more records visible. | The list loads within a few seconds — comparable to other standard BC list pages. |
| 2 | Scroll through the full list end-to-end. | Scrolling is smooth. The page does not repeatedly reload or freeze. |
| 3 | Note the approximate time to fully render the list. | Render time is acceptable for the record count. Document the observed load time. |
Test Area 8: Stale Lock Auto-Release
Requirement: Locks older than the configured timeout are automatically cleared when another user opens the order.
Verify that stale locks are detected and auto-cleared based on the Locked At timestamp and the configured Stale Lock Timeout. These tests require either (a) adjusting the timeout to a low value (1 hour) and waiting, or (b) directly manipulating the Locked At field on a test record to simulate an aged lock.
To simulate a stale lock without waiting: use Developer Tools or an admin page to set the Locked At field on a test Service Order to a timestamp older than the configured timeout (e.g., yesterday). Then open the order as a different user to trigger the stale check.
TC-8.1: Stale Lock Is Auto-Cleared on Page Open
| Step | Action | Expected Result |
|---|
| 1 | Create a stale lock: set Check Status = true, Open By User ID = User A, and Locked At to a timestamp older than the configured timeout on a test order. | The test order shows as locked by User A with an aged timestamp. |
| 2 | User B opens the same service order card. | No lockout message is shown. The stale lock is automatically cleared. |
| 3 | User B can edit the order normally. | The page is fully editable. User B holds the lock. |
| 4 | (Optional) Inspect the Service Header record. | Check Status = true. Open By User ID = User B. Locked At = current timestamp. |
TC-8.2: Non-Stale Lock Is NOT Auto-Cleared
| Step | Action | Expected Result |
|---|
| 1 | User A opens a service order normally (creating a fresh lock). | User A holds a lock with a current Locked At timestamp. |
| 2 | User B opens the same order within a few minutes. | User B receives the standard lockout message identifying User A. The lock is NOT auto-cleared. |
| 3 | User B clicks OK and enters read-only mode. | User B is in View Only mode. The fresh lock was correctly preserved. |
TC-8.3: Lock with No Timestamp Is Treated as Stale
| Step | Action | Expected Result |
|---|
| 1 | Create a lock with no timestamp: set Check Status = true, Open By User ID = User A, and Locked At = 0DT (empty/blank) on a test order. | The test order shows as locked by User A with no timestamp. |
| 2 | User B opens the same service order card. | No lockout message is shown. The lock with no timestamp is treated as stale and auto-cleared. |
| 3 | User B can edit the order normally. | The page is fully editable. User B holds the lock with a current timestamp. |
| Step | Action | Expected Result |
|---|
| 1 | Set the Stale Lock Timeout to 1 hour on the Service Order Lockout Setup page. | Timeout is saved as 1 hour. |
| 2 | Create a stale lock with Locked At set to 2 hours ago on a test order. | The lock is older than the 1-hour timeout. |
| 3 | User B opens the order. Confirm the stale lock is auto-cleared. | Lock is auto-cleared. User B can edit. |
| 4 | Create another lock with Locked At set to 30 minutes ago on a different test order. | The lock is newer than the 1-hour timeout. |
| 5 | User B opens this order. Confirm the lock is NOT auto-cleared. | User B receives the lockout message. The fresh lock is preserved. |
| 6 | Reset the Stale Lock Timeout to 4 hours. | Timeout restored to default. |
Test Area 9: Release Lock Action
Requirement: SUPER users can manually force-release a stuck lock from the Service Order card.
Verify the Release Lock action is available, correctly gated to SUPER users, and properly transfers the lock.
TC-9.1: Release Lock Action Is Visible When a Lock Exists
| Step | Action | Expected Result |
|---|
| 1 | User A opens a service order to acquire the lock. | User A holds the lock. |
| 2 | User C (SUPER) opens the same order and receives the lockout message. Click OK. | User C is in View Only mode. |
| 3 | Inspect the Processing actions on the action bar. | A 'Release Lock' action is visible and enabled. |
TC-9.2: Release Lock Action Is Disabled When No Lock Exists
| Step | Action | Expected Result |
|---|
| 1 | User C (SUPER) opens a service order that is NOT currently locked. | The order opens normally. User C holds the lock. |
| 2 | Inspect the Processing actions on the action bar. | The 'Release Lock' action is visible but disabled (grayed out), because User C already holds the lock via normal acquisition. |
TC-9.3: Release Lock Transfers the Lock to the SUPER User
| Step | Action | Expected Result |
|---|
| 1 | User A holds a lock on an order. User C (SUPER) opens the order and is in View Only mode. | User C sees the lockout message and clicks OK. |
| 2 | User C clicks the 'Release Lock' action. | A confirmation dialog appears: 'Release the lock held by [User A] on this Service Order?' |
| 3 | User C confirms the release. | A message appears: 'Lock released and reassigned to you.' The page becomes editable. |
| 4 | (Optional) Inspect the Service Header record. | Check Status = true. Open By User ID = User C. Locked At = current timestamp. |
TC-9.4: Non-SUPER User Cannot Use Release Lock
| Step | Action | Expected Result |
|---|
| 1 | User A holds a lock on an order. User B (BW-CS-SERVICE, no SUPER) opens the order and enters View Only mode. | User B is in read-only mode. |
| 2 | User B attempts to click the 'Release Lock' action (if visible). | Either the action is not visible, or clicking it produces an error: 'You must have the SUPER role to release another user's lock.' |
TC-9.5: Release Lock Can Be Cancelled
| Step | Action | Expected Result |
|---|
| 1 | User C (SUPER) opens a locked order and is in View Only mode. | User C sees the lockout message. |
| 2 | User C clicks the 'Release Lock' action. The confirmation dialog appears. | The dialog asks for confirmation. |
| 3 | User C clicks 'No' (cancel). | The dialog closes. The lock is NOT released. The page remains in View Only mode. |
Test Area 10: Service Order Lockout Setup
Requirement: Administrators can enable/disable lockout and configure the stale lock timeout.
Verify the configuration page is accessible, settings persist, and the lockout toggle correctly enables or disables all locking behavior.
TC-10.1: Setup Page Is Accessible and Shows Defaults
| Step | Action | Expected Result |
|---|
| 1 | Search for 'Service Order Lockout Setup' in the BC search bar. | The page appears in the search results. |
| 2 | Open the Service Order Lockout Setup page. | The page opens showing two fields: Lockout Enabled and Stale Lock Timeout (Hours). |
| 3 | Verify default values. | Lockout Enabled = true (checked). Stale Lock Timeout (Hours) = 4. |
TC-10.2: Disabling Lockout Bypasses All Locking Behavior
| Step | Action | Expected Result |
|---|
| 1 | On the Service Order Lockout Setup page, uncheck 'Lockout Enabled' and save. | Lockout Enabled = false. |
| 2 | User A opens a service order. | The order opens normally. No lock is acquired. |
| 3 | User B opens the same order simultaneously. | No lockout message is shown. Both users can edit the order concurrently. |
| 4 | Navigate to the Service Orders list. | The Live Status column is hidden (not visible). |
| 5 | Re-enable 'Lockout Enabled' on the setup page. | Lockout Enabled = true. Restore for subsequent tests. |
TC-10.3: Stale Lock Timeout Has Valid Range
| Step | Action | Expected Result |
|---|
| 1 | On the Service Order Lockout Setup page, attempt to set Stale Lock Timeout to 0. | BC displays a validation error. The minimum value is 1. |
| 2 | Attempt to set Stale Lock Timeout to 73. | BC displays a validation error. The maximum value is 72. |
| 3 | Set Stale Lock Timeout to 8 and save. | The value saves successfully as 8. |
| 4 | Reset Stale Lock Timeout to 4. | Default restored. |
TC-10.4: Settings Persist Across Sessions
| Step | Action | Expected Result |
|---|
| 1 | Set Stale Lock Timeout to 6 hours and close the setup page. | The value is saved. |
| 2 | Open a new BC session and navigate to Service Order Lockout Setup. | The page opens. |
| 3 | Verify the Stale Lock Timeout value. | The value is 6, confirming it persisted across sessions. |
| 4 | Reset to 4 hours. | Default restored. |
Test Area 11: Record Navigation Lock Handling
Requirement: Navigating between Service Orders via Next/Previous on the card must correctly release the previous lock and acquire a new one.
Verify that the lock follows the currently displayed record, not just the first record opened.
TC-11.1: Navigating to Next Record Releases Previous Lock
| Step | Action | Expected Result |
|---|
| 1 | User A opens Service Order #1 from the list. | Order #1 opens and User A holds the lock. Note the order number. |
| 2 | User A clicks the 'Next' arrow (or keyboard shortcut) to navigate to Order #2. | Order #2 is now displayed on the card. |
| 3 | (Optional) Inspect Order #1 in the Service Header table. | Order #1: Check Status = false. Open By User ID = blank. The lock was released. |
| 4 | (Optional) Inspect Order #2 in the Service Header table. | Order #2: Check Status = true. Open By User ID = User A. The new lock was acquired. |
TC-11.2: Navigating to Previous Record Releases Current Lock
| Step | Action | Expected Result |
|---|
| 1 | From TC-11.1, User A clicks the 'Previous' arrow to navigate back to Order #1. | Order #1 is now displayed on the card. |
| 2 | (Optional) Inspect Order #2 in the Service Header table. | Order #2: Check Status = false. Open By User ID = blank. The lock was released. |
| 3 | (Optional) Inspect Order #1. | Order #1: Check Status = true. Open By User ID = User A. The lock was re-acquired. |
TC-11.3: Navigating Into a Locked Record Shows Lockout Message
| Step | Action | Expected Result |
|---|
| 1 | User B opens and holds a lock on Order #3. | User B holds the lock on Order #3. |
| 2 | User A opens Order #2 (adjacent to Order #3 in the list). | User A holds the lock on Order #2. |
| 3 | User A navigates forward to Order #3. | User A receives the lockout message identifying User B and enters View Only mode for Order #3. |
| 4 | (Optional) Inspect Order #2. | Order #2: Check Status = false. The previous lock was released even though the new record is locked by someone else. |
TC-11.4: Closing the Card After Navigation Releases the Current Lock
| Step | Action | Expected Result |
|---|
| 1 | User A opens Order #1, navigates to Order #2, then navigates to Order #3. | User A is viewing Order #3. |
| 2 | User A closes the Service Order card. | The card closes normally. |
| 3 | (Optional) Inspect Orders #1, #2, and #3. | Order #3: Check Status = false (released on close). Orders #1 and #2: Check Status = false (released during navigation). No orphaned locks remain. |
Test Area 12: SUPER User Behavior
Requirement: SUPER users can access Service Orders without BW-CS-SERVICE and can use the Release Lock action.
Verify the full SUPER user workflow — access, locking, and the Release Lock action — without the BW-CS-SERVICE permission set assigned.
TC-12.1: SUPER User Can Open and Lock a Service Order
| Step | Action | Expected Result |
|---|
| 1 | User C (SUPER, no BW-CS-SERVICE) opens a service order card. | The card opens normally. No permission error is shown. |
| 2 | (Optional) Inspect the Service Header record. | Check Status = true. Open By User ID = User C. The SUPER user acquired the lock like any other user. |
| 3 | User C closes the order. | The lock is released. Check Status = false. |
TC-12.2: SUPER User Sees Lockout Message for Orders Locked by Others
| Step | Action | Expected Result |
|---|
| 1 | User A (BW-CS-SERVICE) opens and holds a lock on a service order. | User A holds the lock. |
| 2 | User C (SUPER) opens the same order. | User C receives the standard lockout message identifying User A and enters View Only mode. |
| 3 | User C can use the Release Lock action to override. | The Release Lock action is enabled and functional (covered in detail in Test Area 9). |
TC-12.3: SUPER User Lock Is Respected by CS Users
| Step | Action | Expected Result |
|---|
| 1 | User C (SUPER) opens a service order and holds the lock. | User C holds the lock. |
| 2 | User A (BW-CS-SERVICE) opens the same order. | User A receives the lockout message identifying User C and enters View Only mode. |
| 3 | User A cannot use the Release Lock action. | The Release Lock action is either hidden or produces an error when clicked (User A does not have SUPER). |